Skip to content

feat: update model registry to April 2026 (TMC-92)#431

Closed
tmcinerney wants to merge 4 commits intoBeehiveInnovations:mainfrom
tmcinerney:tmcinerney/tmc-92-update-pal-mcp-model-registry-to-april-2026-models
Closed

feat: update model registry to April 2026 (TMC-92)#431
tmcinerney wants to merge 4 commits intoBeehiveInnovations:mainfrom
tmcinerney:tmcinerney/tmc-92-update-pal-mcp-model-registry-to-april-2026-models

Conversation

@tmcinerney
Copy link
Copy Markdown

Summary

  • Add 5 OpenAI models: GPT-5.4, GPT-5.4 Pro, GPT-5.4 Mini, GPT-5.4 Nano, GPT-5.3 Codex
  • Add 3 Gemini models: 3.1 Pro Preview, 3 Flash Preview, 3.1 Flash Lite Preview
  • Remove dead/retired models: gpt-4.1, gemini-3-pro-preview (already 404 since March 9), gemini-2.0-flash, gemini-2.0-flash-lite
  • Mark Gemini 2.5 Pro and 2.5 Flash as deprecated (June 17 shutdown)
  • Fix Gemini provider to use thinking_level enum for 3.x models instead of thinking_budget (breaking API change - 3.x models 400-error without this)
  • Fix preference selection to exclude flash-lite from flash candidates
  • Fix registry to use canonical names only in preference selection (latent alias sort-order bug)
  • Update 15 test files with new model names and expected selections

Test plan

  • ./code_quality_checks.sh passes (ruff, black, isort)
  • 852 unit tests pass, 0 regressions (14 pre-existing failures unrelated to this change)
  • Verified google-genai SDK supports ThinkingConfig(thinking_level='HIGH')
  • No remaining references to removed models in Python files
  • Smoke test with real API keys against Gemini 3.1 Pro and GPT-5.4

Closes TMC-92

🤖 Generated with Claude Code

tmcinerney and others added 4 commits April 15, 2026 20:36
Migrate from pip/requirements.txt workflow to uv-native dependency
management with devenv for reproducible development environments.
Bumps Python target to 3.14 and requires-python to >=3.12.

- Add .python-version as single source of truth for Python version
- Add [dependency-groups] dev/lint to pyproject.toml, replacing
  requirements-dev.txt as canonical dev deps
- Add uv.lock for deterministic dependency resolution
- Add secretspec.toml + devenv.local.yaml for declarative 1Password
  secret management via SecretSpec
- Modernize code_quality_checks.sh and run_integration_tests.sh to
  use uv sync and direct tool invocation instead of .pal_venv/pip
- Update ruff target-version to py312, black to py312/py313
- Update .pre-commit-config.yaml excludes for .devenv/
- Update isort skip_glob for .devenv/
- Apply ruff 0.15 auto-fixes (pyupgrade, asyncio.TimeoutError -> TimeoutError, etc.)

Co-Authored-By: Claude <noreply@anthropic.com>
Remove devenv.local.yaml (contains personal 1Password vault ID) from
tracking and add devenv artifacts to .gitignore. Un-ignore
.python-version so it's tracked as the Python version source of truth.

Co-Authored-By: Claude <noreply@anthropic.com>
Commit standalone devenv.nix, devenv.yaml, and .envrc so anyone can
clone the repo and get a working environment with `devenv shell`.
No personal config - devenv.local.yaml (for secret providers like
1Password) stays gitignored.

SecretSpec secrets marked optional so devenv starts without API keys
(needed for linting/tests, not for API calls).

Co-Authored-By: Claude <noreply@anthropic.com>
Add GPT-5.4 family (5.4, 5.4 Pro, 5.4 Mini, 5.4 Nano) and GPT-5.3 Codex.
Add Gemini 3.1 Pro Preview, 3 Flash Preview, and 3.1 Flash Lite Preview.
Remove dead/retired models: gpt-4.1, gemini-3-pro-preview (already 404),
gemini-2.0-flash, gemini-2.0-flash-lite. Mark Gemini 2.5 models as
deprecated (June 17 shutdown).

Fix Gemini provider to branch on thinking_level (3.x enum API) vs
thinking_budget (2.x numeric API) - without this, 3.x models 400-error
on thinking requests. Fix preference selection to exclude flash-lite from
flash candidates. Fix registry to use canonical names only in preference
selection (was including aliases, causing sort-order bugs).

Co-Authored-By: Claude <noreply@anthropic.com>
@chatgpt-codex-connector
Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@tmcinerney tmcinerney closed this Apr 16, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces significant updates to the model provider configurations, including the adoption of Gemini 3.1 and GPT-5.4 models, updates to the development environment using devenv and uv, and a transition to modern Python type hinting syntax (e.g., | None). The review identified potential fragility in the Gemini 3.x model identification and Pro model detection logic, as well as a need for better error messaging in the code quality check script.

Comment thread providers/gemini.py
Comment on lines +210 to +211
if level == "MINIMAL" and "pro" in resolved_model_name:
level = "LOW"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The check if level == "MINIMAL" and "pro" in resolved_model_name: is fragile. If a model name contains 'pro' but is not a Pro model, this logic will fail. Consider using a more robust way to identify Pro models, such as checking against a list of known Pro model names or a capability flag.

Comment thread code_quality_checks.sh
Comment on lines +15 to 18
if ! command -v uv &> /dev/null; then
echo "Error: uv not found. Activate devenv first (cd into repo with direnv, or run devenv shell)."
exit 1
fi
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The script uses command -v uv to check for uv. If uv is not found, it exits with an error. It is better to provide instructions on how to install uv or how to set up the environment properly, rather than just stating it is not found.

Comment thread providers/gemini.py
Comment on lines +56 to +58
def _is_gemini_3x(model_name: str) -> bool:
"""Return True if the model uses the Gemini 3.x thinking_level API."""
return model_name.startswith("gemini-3")
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The _is_gemini_3x method uses model_name.startswith("gemini-3"). This might incorrectly identify future models (e.g., 'gemini-30-pro') as 3.x models. It is safer to use a more specific check, such as model_name.startswith(("gemini-3.", "gemini-3-")).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant